<?php if (!defined('THINK_PATH')) exit();?><div class="bjui-pageHeader">
    <form id="pagerForm" data-toggle="ajaxsearch" action="<?php echo U(index);?>" method="post">
        <input type="hidden" name="pageCurrent"     value="<?php echo ($pageCurrent); ?>"/>
        <input type="hidden" name="pageSize"        value="<?php echo ($pageSize); ?>"/>
        <div class="bjui-searchBar">
            <label>搜索：</label>
            <input type="text" value="<?php echo ((isset($searchname) && ($searchname !== ""))?($searchname):""); ?>" name="searchname" class="form-control" size="10" />&nbsp;
            <button type="submit" class="btn-default" data-icon="search">查询</button>&nbsp;
            <a class="btn btn-orange" href="javascript:;" data-toggle="reloadsearch" data-clear-query="true" data-icon="undo">清空查询</a>
            <a href="<?php echo U(add);?>" class="btn btn-green" data-toggle="dialog">添加医院</a>
            <div class="pull-right">
                <a href="<?php echo U(del);?>" data-toggle="doajaxchecked" data-confirm-msg="确定要删除选中项吗？" data-idname="ids" data-group="ids" class="btn btn-red">删除选中</a>
            </div>
        </div>
    </form>
</div>
<div class="bjui-pageContent">
    <table data-toggle="tablefixed" data-width="100%">
        <thead>
            <tr>
                <th>序号</th>
                <th orderField="name">医院名称</th>
                <th orderField="author" >管理员</th>
                <th orderField="status">状态</th>
                <th orderField="addtime" >添加时间</th>
                <th orderField="lasttime" >最后修改时间</th>
                <th width="26">
                    <input type="checkbox" class="checkboxCtrl" data-group="ids" data-toggle="icheck"></th>
                <th width="100">操作</th>
            </tr>
        </thead>
        <tbody>
            <?php if(empty($list)): ?><td colspan="8" class="text-center">Oh! 暂时还没有内容!</td>
                <?php else: ?>
                <?php if(is_array($list)): $i = 0; $__LIST__ = $list;if( count($__LIST__)==0 ) : echo "" ;else: foreach($__LIST__ as $key=>$vo): $mod = ($i % 2 );++$i;?><tr>
                        <td><?php echo ($i); ?></td>
                        <td><?php echo ($vo["name"]); ?></td>
                        <td><?php echo ($vo["author"]); ?></td>
                        <td>
                            <?php if($vo["status"] == 1): ?>启用
                                <?php else: ?>
                                禁用<?php endif; ?>
                        </td>
                        <td><?php echo (date("Y-m-d:h",$vo["addtime"])); ?></td>
                        <td><?php echo (date("Y-m-d:h",$vo["lasttime"])); ?></td>
                        <td>
                            <input type="checkbox" name="ids" data-toggle="icheck" value="<?php echo ($vo["id"]); ?>"></td>
                        <td>
                            <a href="<?php echo U('edit',array('id'=>$vo['id']));?>" class="btn btn-green" data-toggle="dialog" data-title="编辑医院">编辑</a>
                            <a href="<?php echo U('del',array('ids'=>$vo['id']));?>" class="btn btn-red" data-toggle="doajax" data-confirm-msg="确定要删除该行信息吗？">删</a>
                        </td>
                    </tr><?php endforeach; endif; else: echo "" ;endif; endif; ?>
        </tbody>
    </table>
</div>
<div class="bjui-pageFooter">
    <div class="pages">
        <span>每页&nbsp;</span>
        <div class="selectPagesize">
            <select data-toggle="selectpicker" data-toggle-change="changepagesize">
                <option value="<?php echo ($pageSize); ?>"><?php echo ($pageSize); ?></option>
                <option value="10">10</option>
                <option value="20">20</option>
                <option value="30">30</option>
                <option value="60">60</option>
                <option value="100">100</option>
            </select>
        </div>
        <span>共<?php echo ($total); ?>条</span>
    </div>
    <div class="pagination-box" data-toggle="pagination" data-total="<?php echo ($total); ?>" data-page-size="<?php echo ($pageSize); ?>" data-page-current="<?php echo ($pageCurrent); ?>"></div>
</div>